<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        li{
            list-style: none;
        }
        .box {
            width: 1000px;
            height: 400px;
            margin: 100px auto;
        }
        ul li {
            width: 200px;
            height: 400px;
            float: left;
            overflow: hidden;
        }
    </style>
</head>
<body>
    <div class="box">
        <ul>
            <li><img src="images/1.jpg" alt=""></li>
            <li><img src="images/2.jpg" alt=""></li>
            <li><img src="images/3.jpg" alt=""></li>
            <li><img src="images/4.jpg" alt=""></li>
            <li><img src="images/5.jpg" alt=""></li>
        </ul>
    </div>
    <script src="../jquery-1.12.4.js"></script>
    <script>
        $(function(){
            $('.box li').mouseenter(function(){
                $(this).stop().animate({'width':'800px'},1000).siblings().stop().animate({'width':'50px'},1000);
            })
            $('.box').mouseleave(function(){
                $(this).find('li').stop().animate({'width':'200px'},1000)
            })
        })
    </script>
</body>
</html>